/* Copyright 2018 JDCLOUD.COM

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http:#www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.





Contact: 

NOTE: This class is auto generated by the jdcloud code generator program.
*/

 

#ifndef ContainerregistryModel_h
#define ContainerregistryModel_h

@interface ContainerregistryQuota :NSObject

/// 资源类型 [registry/repository]
@property (strong,nonatomic,nonnull)  NSString*  resourceType;

/// 可用资源上限
@property (strong,nonatomic,nonnull)  NSNumber*  limit;

/// 已用资源数量
@property (strong,nonatomic,nonnull)  NSNumber*  used;


-(id) initWithResourceType:(NSString*) resourceType
    limit:(NSNumber*)limit
    used:(NSNumber*)used;
-(NSMutableDictionary*) dictionary;

-(id) initWithDic:(NSDictionary*)dictionary;                    
@end
@interface Registry :NSObject

/// 注册表名称，&lt;a href&#x3D;&quot;https://www.jdcloud.com/help/detail/3870/isCatalog/1&quot;&gt;参考公共参数规范&lt;/a&gt;。
@property (strong,nonatomic,nonnull)  NSString*  name;

/// registry endporint url
@property (strong,nonatomic,nonnull)  NSString*  registryUri;

/// 注册表描述，&lt;a href&#x3D;&quot;https://www.jdcloud.com/help/detail/3870/isCatalog/1&quot;&gt;参考公共参数规范&lt;/a&gt;。
@property (strong,nonatomic,nonnull)  NSString*  descriptionValue;

/// regsitry 使用的总存储空间 单位 (MB)
@property (strong,nonatomic,nonnull)  NSNumber*  totalSpaceUsedMB;

/// registry 的创建时间
@property (strong,nonatomic,nonnull)  NSString*  createTime;


-(id) initWithName:(NSString*) name
    registryUri:(NSString*)registryUri
    descriptionValue:(NSString*)descriptionValue
    totalSpaceUsedMB:(NSNumber*)totalSpaceUsedMB
    createTime:(NSString*)createTime;
-(NSMutableDictionary*) dictionary;

-(id) initWithDic:(NSDictionary*)dictionary;                    
@end
@interface Repository :NSObject

/// 记录用户repository创建的时间。
@property (strong,nonatomic,nonnull)  NSString*  createdAt;

/// 记录用户repository更新的时间。
@property (strong,nonatomic,nonnull)  NSString*  updatedAt;

/// 注册表名称。
@property (strong,nonatomic,nonnull)  NSString*  registryName;

/// 镜像仓库名称。
@property (strong,nonatomic,nonnull)  NSString*  repositoryName;

/// 镜像仓库中的镜像总个数。
@property (strong,nonatomic,nonnull)  NSString*  repositoryUri;

/// 镜像仓库大小。
@property (strong,nonatomic,nonnull)  NSNumber*  totalSpaceUsedMB;

/// 镜像仓库描述。
@property (strong,nonatomic,nonnull)  NSString*  descriptionValue;


-(id) initWithCreatedAt:(NSString*) createdAt
    updatedAt:(NSString*)updatedAt
    registryName:(NSString*)registryName
    repositoryName:(NSString*)repositoryName
    repositoryUri:(NSString*)repositoryUri
    totalSpaceUsedMB:(NSNumber*)totalSpaceUsedMB
    descriptionValue:(NSString*)descriptionValue;
-(NSMutableDictionary*) dictionary;

-(id) initWithDic:(NSDictionary*)dictionary;                    
@end
@interface ImageDetail :NSObject

/// image registry 表示镜像的注册表归属
@property (strong,nonatomic,nonnull)  NSString*  registryName;

/// image repository表示镜像的仓库归属
@property (strong,nonatomic,nonnull)  NSString*  repositoryName;

/// image manifest的sha256摘要
@property (strong,nonatomic,nonnull)  NSString*  imageDigest;

/// 镜像的Manifest
@property (strong,nonatomic,nonnull)  NSString*  imageManifest;

/// 当前image被push到repository的时间
@property (strong,nonatomic,nonnull)  NSString*  imagePushedAt;

/// image在repository中的大小。从Docker 1.9之后的版本, Docker client会压缩镜像层数据再push到V2版本的Docker registry。
   /// docker image命令显示的是解压后的镜像大小，因此会比DescribeImages接口返回的镜像大小会大很多。      
   /// 
@property (strong,nonatomic,nonnull)  NSNumber*  imageSizeMB;

/// 镜像关联的所有Tag
@property (strong,nonatomic,nonnull)  NSArray<NSString*>*  imageTags;

/// 最近pull的时间
@property (strong,nonatomic,nonnull)  NSString*  lastPullAt;

/// 镜像被拉取次数
@property (strong,nonatomic,nonnull)  NSNumber*  totalPullTimes;


-(id) initWithRegistryName:(NSString*) registryName
    repositoryName:(NSString*)repositoryName
    imageDigest:(NSString*)imageDigest
    imageManifest:(NSString*)imageManifest
    imagePushedAt:(NSString*)imagePushedAt
    imageSizeMB:(NSNumber*)imageSizeMB
    imageTags:(NSArray<NSString*>*)imageTags
    lastPullAt:(NSString*)lastPullAt
    totalPullTimes:(NSNumber*)totalPullTimes;
-(NSMutableDictionary*) dictionary;

-(id) initWithDic:(NSDictionary*)dictionary;                    
@end
@interface AuthorizationData :NSObject

/// 基于base64编码的字符串，包含指定JCR registry的授权信息。解码后可用于docker login。
@property (strong,nonatomic,nonnull)  NSString*  authorizationToken;

/// 用户直接使用的docker login 命令行
@property (strong,nonatomic,nonnull)  NSString*  loginCmdLine;

/// Unix 时钟，记录authorization token的过期时间。默认Authorization tokens有效期为12小时。
@property (strong,nonatomic,nonnull)  NSString*  expiresAt;


-(id) initWithAuthorizationToken:(NSString*) authorizationToken
    loginCmdLine:(NSString*)loginCmdLine
    expiresAt:(NSString*)expiresAt;
-(NSMutableDictionary*) dictionary;

-(id) initWithDic:(NSDictionary*)dictionary;                    
@end
@interface RepositoryShort :NSObject

/// 记录用户repository创建的时间。
@property (strong,nonatomic,nonnull)  NSString*  createdAt;

/// 镜像仓库repository名称。
@property (strong,nonatomic,nonnull)  NSString*  repositoryName;

/// repository的URI，用户通过docker CLI,制定该URI直接进行docker pull/push等操作。
@property (strong,nonatomic,nonnull)  NSString*  repositoryUri;


-(id) initWithCreatedAt:(NSString*) createdAt
    repositoryName:(NSString*)repositoryName
    repositoryUri:(NSString*)repositoryUri;
-(NSMutableDictionary*) dictionary;

-(id) initWithDic:(NSDictionary*)dictionary;                    
@end

#endif /* ContainerregistryModel_h */
